#pragma once
#include "Extra Headers.h"
#include "Word.h"

//Security holds two key value pairs, it holds the time(month date year), and the entry page at that date
// It can encrypt and decrypt both of them
struct _SECURITY
{
	struct _SECURITY * Prev;
	struct _SECURITY * Next;
	struct _WORD * Time;
	struct _WORD * Info;
	BOOLEAN Encoded;
};

struct _SECURITY * Security_Create();

struct _SECURITY * Security_Create_Linked(struct _SECURITY * NextS,struct _SECURITY * PrevS);

void Create_Words(struct _SECURITY * S);

void Security_Encode(struct _SECURITY * S,struct _BUFFER * TIME,struct _BUFFER * INFO);

void Security_Encrypt(struct _SECURITY * S);

void Security_Decrypt(struct _SECURITY * S);